
package app;

import java.util.Random;

/**
 * @author seberm
 */
public class CPU extends Player {
	// Artibutes: //
	
	
	// Constructors: //
	public CPU (String name) {
		super(name);
	}

	// Methods: //
	public void start() {
		this.setNull();

		// This random number affects the thinking of CPU player
		// Generates random number (rNum) and sum (this.cardsSum) of cpu cards increases until is smaller than rNum
		int rNum = new Random().nextInt(6) + 14;
		while (this.cardsSum < rNum){
			this.getRandom();
		}
	}

}
